import Vue from 'vue'
import './plugins/axios'
import App from './App.vue'
import router from './routers'
import store from './stores'

Vue.config.productionTip = false

// 引入css
import '@/assets/css/common.css'
import '@/assets/css/iconfont/iconfont.css'

import ElementUI from 'element-ui'
import './styles.scss'

Vue.use(ElementUI)

// 引入swiper
import VueAwesomeSwiper from 'vue-awesome-swiper'
import 'swiper/dist/css/swiper.css'
Vue.use(VueAwesomeSwiper, /* { default global options } */)

// 定义全局过滤器
Vue.filter('setWH', (url, arg)=>{
  return url.replace(/w\.h/, arg)
})

// 引入scroll组件
import Scroll from '@/components/common/Scroll'
Vue.component('Scroll', Scroll)
// loading组件
import Loading from '@/components/common/Loading'
Vue.component('Loading', Loading)

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
